Optimal. Leaf size=17 \[ b x-\frac {a \tanh ^{-1}(\cos (e+f x))}{f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 17, normalized size of antiderivative = 1.00, number of steps
used = 2, number of rules used = 2, integrand size = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {2814, 3855}
\begin {gather*} b x-\frac {a \tanh ^{-1}(\cos (e+f x))}{f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2814
Rule 3855
Rubi steps
\begin {align*} \int \csc (e+f x) (a+b \sin (e+f x)) \, dx &=b x+a \int \csc (e+f x) \, dx\\ &=b x-\frac {a \tanh ^{-1}(\cos (e+f x))}{f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(43\) vs. \(2(17)=34\).
time = 0.01, size = 43, normalized size = 2.53 \begin {gather*} b x-\frac {a \log \left (\cos \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{f}+\frac {a \log \left (\sin \left (\frac {e}{2}+\frac {f x}{2}\right )\right )}{f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.18, size = 31, normalized size = 1.82
method | result | size |
derivativedivides | \(\frac {a \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )+b \left (f x +e \right )}{f}\) | \(31\) |
default | \(\frac {a \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )+b \left (f x +e \right )}{f}\) | \(31\) |
risch | \(b x +\frac {a \ln \left ({\mathrm e}^{i \left (f x +e \right )}-1\right )}{f}-\frac {a \ln \left ({\mathrm e}^{i \left (f x +e \right )}+1\right )}{f}\) | \(40\) |
norman | \(\frac {b x +b x \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{1+\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )}+\frac {a \ln \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{f}\) | \(51\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.27, size = 32, normalized size = 1.88 \begin {gather*} \frac {{\left (f x + e\right )} b - a \log \left (\cot \left (f x + e\right ) + \csc \left (f x + e\right )\right )}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 40 vs.
\(2 (18) = 36\).
time = 0.35, size = 40, normalized size = 2.35 \begin {gather*} \frac {2 \, b f x - a \log \left (\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) + a \log \left (-\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right )}{2 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 48 vs.
\(2 (14) = 28\).
time = 2.81, size = 51, normalized size = 3.00 \begin {gather*} a \left (\begin {cases} \frac {x \cot {\left (e \right )} \csc {\left (e \right )}}{\cot {\left (e \right )} + \csc {\left (e \right )}} + \frac {x \csc ^{2}{\left (e \right )}}{\cot {\left (e \right )} + \csc {\left (e \right )}} & \text {for}\: f = 0 \\- \frac {\log {\left (\cot {\left (e + f x \right )} + \csc {\left (e + f x \right )} \right )}}{f} & \text {otherwise} \end {cases}\right ) + b x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.46, size = 27, normalized size = 1.59 \begin {gather*} \frac {{\left (f x + e\right )} b + a \log \left ({\left | \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right ) \right |}\right )}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 6.80, size = 85, normalized size = 5.00 \begin {gather*} \frac {a\,\ln \left (\frac {\sin \left (\frac {e}{2}+\frac {f\,x}{2}\right )}{\cos \left (\frac {e}{2}+\frac {f\,x}{2}\right )}\right )}{f}+\frac {2\,b\,\mathrm {atan}\left (\frac {b\,\cos \left (\frac {e}{2}+\frac {f\,x}{2}\right )+a\,\sin \left (\frac {e}{2}+\frac {f\,x}{2}\right )}{a\,\cos \left (\frac {e}{2}+\frac {f\,x}{2}\right )-b\,\sin \left (\frac {e}{2}+\frac {f\,x}{2}\right )}\right )}{f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________